public class Test {

    public static void test(){
        int i = 1;
        while(i++ <= 100){
            if(i % 3 == 0||i % 5 == 0){
                System.out.print(i+" ");
            }
        }
    }
    public static int findKey(int[] nums,int key){
        int index = 0;
        for (int i = 0; i < nums.length; i++) {
            if(nums[i] == key){
                return index;
            }
        }
        return -1;
    }


    public static void main(String[] args) {
        test();
    }
}
